package com.vm.osm.business.service;

import com.vm.osm.business.dto.req.failOrder.ReqAddFailOrder;
import com.vm.osm.business.dto.req.failOrder.ReqDispatchFail;
import com.vm.osm.business.dto.req.failOrder.ReqSearchFailureOrder;
import com.vm.osm.business.dto.rsp.failOrder.RspFailOrderDetail;
import com.vm.osm.business.dto.rsp.failOrder.RspFailOrderPage;
import com.vm.osm.business.dto.rsp.orderInst.RspMaintenancePage;
import com.vm.osm.business.entity.OsmOrderFailure;
import org.apache.ibatis.annotations.Param;

import javax.servlet.http.HttpServletRequest;
import java.util.Map;

/**
 * Created by chenzui on 2018/3/13.
 */
public interface IOrderFailureService extends IBaseService<OsmOrderFailure,String> {
    public RspFailOrderPage queryOrderFailureByCond(ReqSearchFailureOrder reqSearchFailureOrder);

    public RspFailOrderDetail getOrderFailureById(String id);

    public void handleOrder(String id, String status, String remark,String staffName,String staffId);

    /**
     * 内部派单
     * @param reqDispatchFail
     */
    public void dispatchIn(ReqDispatchFail reqDispatchFail);

    public RspFailOrderPage queryOrderFailureByStaffId(Integer pageNum,Integer pageSize,String staffId);

    /**
     * 按条件查询单个
     *
     * @param params 查询条件
     * @return 记录
     */
    OsmOrderFailure get(Map<String, Object> params);

    public void specialCommit(ReqAddFailOrder reqAddFailOrder, HttpServletRequest request);

    public RspMaintenancePage queryOrderByDeviceId(Integer pageNum, Integer pageSize, String deviceId);

    public String commit(ReqAddFailOrder reqAddFailOrder, HttpServletRequest request);
}
